using Gobang;
using UnityEngine;

public class Button_Revoke : MyButton
{
    private ChessboardMono mono;
    [SerializeField]
    private int times;

    protected override void OnClick()
    {
        mono.Revoke(times);
    }

    protected override void Awake()
    {
        base.Awake();
        mono = ChessboardMono.FindInstance();
    }

    private void Update()
    {
        Button.interactable = mono.CanRevoke;
    }
}
